//
// Created by zhku666 on 25-2-24.
//
#include <cstdio>
#include "cattle.cpp"
#include "sensor.cpp"
#include "bind.cpp"

void menu()
{
    //TODO 健壮性
    int input=0;
    while (true)
    {
        printf("--------------菜单--------------\n");
        printf("1.管理牛群\n");
        printf("2.管理传感器\n");
        printf("3.绑定\n");
        printf("输入其他退出\n");
        scanf_s("%d",&input);
        switch (input)
        {
        case 1:
            cattle();
            break;
        case 2:
            sensor();
            break;
        case 3:
            bind();
            break;
        default:
            printf("退出成功！\n");
            exit(0);
        }
    }
}
